import XEUtils from 'xe-utils'

export const formatterDate = (row: any, propName: string) => {
	if (row[propName]) {
		return XEUtils.toDateString(row[propName], 'yyyy-MM-dd')
	}
	return '--'
}

export const formatDate = (date: Date | undefined) => {
	if (date) {
		return XEUtils.toDateString(date, 'yyyy-MM-dd')
	}
	return '--'
}
